Ensure CR0.TS is set for VMX domains regardless of the current
authorSteven Hand <steven@xensource.com>
Mon, 4 Jun 2007 15:47:48 +0000 (16:47 +0100)
committerSteven Hand <steven@xensource.com>
Mon, 4 Jun 2007 15:47:48 +0000 (16:47 +0100)
state of the real TS bit. This fixes a number of subtle FP
corruption issues within PV domains when running alongside VMX ones.

Signed-off-by: Steven Hand <steven@xensource.com>
xen/arch/x86/hvm/vmx/vmcs.c

index a59fd6ba257d0ca3c42b2b6319e3aaa0b263ca2e..7c9802cbd710730fb68fbec77e3fae103c06a536 100644 (file)
@@ -337,7 +337,7 @@ static void construct_vmcs(struct vcpu *v)
 #endif
 
     /* Host control registers. */
-    __vmwrite(HOST_CR0, read_cr0());
+    __vmwrite(HOST_CR0, read_cr0() | X86_CR0_TS);
     __vmwrite(HOST_CR4, read_cr4());
 
     /* Host CS:RIP. */